﻿<%@ Page Language="C#" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>

<!DOCTYPE html>

<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <title>辅助资料类别列表</title>
    <link href="/Themes/Styles/style.css" rel="stylesheet" />
    <script src="/Themes/Scripts/jquery-1.8.2.min.js"></script>
    <script src="/Themes/Scripts/TreeView/jquery.cookie.js"></script>
    <link href="/Themes/Scripts/TreeView/jquery.treeview.css" rel="stylesheet" />
    <script src="/Themes/Scripts/TreeView/jquery.treeview.js"></script>
    <script src="/Themes/Scripts/FunctionJS.js"></script>
    <script>
        $(function () {
            divresize('.div-body', 76);
            treeAttrCss();
            GetClickValue();
            //动态加载工具栏权限按钮
            Tools_bar();
        })
        //初始化
        var ItemsId, FullName = '';
        function GetClickValue() {
            ItemsId = $('.collapsableselected').attr('id');
            FullName = $('.collapsableselected').find('span').html();
            var path = '/Dictionary/ItemDetailsList?ItemsId=' + ItemsId + '&FullName=' + escape(FullName);
            window.parent.frames["target_right"].location = path;
            Loading(true);

            $(".strTree li div").click(function () {
                ItemsId = $(this).attr('id');
                if (IsNullOrEmpty(ItemsId)) {
                    FullName = $(this).find('span').html();
                    var path = '/Dictionary/ItemDetailsList?ItemsId=' + ItemsId + '&FullName=' + escape(FullName);
                    window.parent.frames["target_right"].location = path;
                    Loading(true);
                }
            });
        }
        //新增
        function add() {
            var url = "/Dictionary/ItemsForm";
            top.openDialog(url, 'ItemsForm', '辅助资料类别 - 添加', 400, 215, 50, 50);
        }
        //编辑
        function edit() {
            var key = ItemsId;
            if (IsEditdata(key)) {
                var url = "/Dictionary/ItemsForm?key=" + key;
                top.openDialog(url, 'ItemsForm', '辅助资料类别 - 编辑', 400, 215, 50, 50);
            }
        }
        //删除
        function Delete() {
            var key = ItemsId;
            if (IsDelData(key)) {
                var delparm = {
                    key: key
                }
                delConfig('/Dictionary/DeleteItems', delparm);
            }
        }
    </script>
</head>
<body>
    <form id="form1">
        <div class="btnbartitle">
            <div>
                辅助资料类别
            </div>
        </div>
        <%--动态加载工具栏权限按钮--%>
        <div class="tools_bar"></div>
        <div class="div-body">
            <ul class="black strTree">
                <%=ViewData["strHtml"] %>
            </ul>
        </div>
    </form>
</body>
</html>
